<template>
  <div>
    <view class="top-banner">
      <van-icon name="wap-home-o" size="72rpx" />
      <view class="title">值得买</view>
      <div class="cont">
        <van-icon name="search" size="72rpx"></van-icon>
        <van-icon name="shopping-cart-o" size="72rpx" />
      </div>
    </view>

    <view class="content">
      <image class="bgc" src="../../static/image/bgc.png" mode="widthFix"></image>
      <view class="header">
        <image class="header-icon" src="../../static/image k=/值得买.png"></image>
        <text class="se-title">严选好物 用心生活</text>
      </view>
      <swiper class="swiper" circular autoplay indicator-dots>
        <swiper-item wx:for="{{ 3 }}" wx:key="1">
          <div class="item">
            <div class="se-item" wx:for="{{ 8 }}" wx:key="1">
              <image class="img" src="../../static/image/goods.png"></image>
              <div class="mainText">每月好物</div>
              <div class="descText">7月必买清单</div>
            </div>
          </div>
        </swiper-item>
      </swiper>
    </view>

    <view>
      <v-card title="名师大咖" subtitle="全部名师>">
        <!-- 给卡片传递参数:子组件  默认插槽-->
        <template>
          <v-item :list="teacherList" type="teacher"></v-item>
        </template>
      </v-card>
    </view>
  </div>
</template>

<script setup>

</script>

<style scoped>
.top-banner {
  width: 750rpx;
  height: 100rpx;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-direction: row;
  position: relative;
  text-align: center;
  vertical-align: middle;
  border-bottom: 0.5rpx solid #ccc;
}

.title {
  line-height: 100rpx;
  font-size: 46rpx;
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  margin: auto;
}

.content {
  position: relative;
  width: 100%;
}

.bgc {
  width: 100%;
}

.header {
  position: absolute;
  top: 0;
  left: 0;
  margin-top: 50rpx;
  margin-left: 20rpx;
  margin-right: 20rpx;
  display: flex;
}

.header-icon {
  width: 130rpx;
  height: 69rpx;
}

.se-title {
  vertical-align: middle;
  height: 69rpx;
  line-height: 69rpx;
  margin-top: 8rpx;
  margin-left: 8rpx;
  color: #fff;
  font-size: 30rpx;
}

.swiper {
  width: 90%;
  margin-left: 5%;
  margin-top: 5%;
  border-radius: 20rpx;
  background-color: #fff;
  position: absolute;
  top: 20%;
  /* border: 1px solid red; */
  /* margin: 24rpx 25rpx; */
  height: calc(100vw*9/16);
  /* margin-left: 1rpx; */
  text-align: center;
}

.item {
  /* width:100rpx ; */
  display: flex;
  align-items: center;
  justify-content: space-around;
  padding: 30rpx;
  flex-wrap: wrap;
}

.img {
  width: 120rpx;
  height: 120rpx;
}

.mainText {
  font-size: 30rpx;
  color: #333;
  font-weight: bold;
}

.descText {
  font-size: 24rpx;
}
</style>